/**
 *  基础方块类
 */

package cn.com.ldns.opentetris.shape;

import cn.com.ldns.opentetris.common.CodeUtil;
import cn.com.ldns.opentetris.shape.model.Position;

public class BoxS extends  BaseBox{
	
	protected Position[] positions_1  ={
		new Position( 0.0f, 0.0f, 0),
		new Position( 0.2f, 0.0f, 0),
		new Position( 0.0f,-0.2f, 0),
		new Position(-0.2f,-0.2f, 0)
	};
	
	protected Position[] positions_2  ={
		new Position( 0.0f, 0.0f, 0),
		new Position( 0.0f, 0.2f, 0),
		new Position(-0.2f, 0.2f, 0),
		new Position(-0.2f, 0.4f, 0)
	};
	
	protected Position[] positions_3  ={
		new Position( 0.0f, 0.0f, 0),
		new Position( 0.2f, 0.0f, 0),
		new Position( 0.0f,-0.2f, 0),
		new Position(-0.2f,-0.2f, 0)
	};
	
	protected Position[] positions_4  ={
		new Position( 0.0f, 0.0f, 0),
		new Position( 0.0f, 0.2f, 0),
		new Position(-0.2f, 0.2f, 0),
		new Position(-0.2f, 0.4f, 0)
	};
	
	public BoxS(){
		super(new Position[]{
			new Position( 0.0f, 0.0f, 0),
			new Position( 0.2f, 0.0f, 0),
			new Position( 0.0f,-0.2f, 0),
			new Position(-0.2f,-0.2f, 0)
		});
	}

	@Override
	protected void initBoxPosition() {
		switch (state) {
			case CodeUtil.STATIC_1:
				positions = positions_1;
				break;
			case CodeUtil.STATIC_2:
				positions = positions_2;
				break;
			case CodeUtil.STATIC_3:
				positions = positions_3;
				break;
			case CodeUtil.STATIC_4:
				positions = positions_4;
			default:
			break;
		}
	}
}
